package com.ruoyi.service.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.service.mapper.CheServiceitemsMapper;
import com.ruoyi.service.domain.CheServiceitems;
import com.ruoyi.service.service.ICheServiceitemsService;

/**
 * 服务管理Service业务层处理
 * 
 * @author ruoyi
 * @date 2024-06-05
 */
@Service
public class CheServiceitemsServiceImpl implements ICheServiceitemsService 
{
    @Autowired
    private CheServiceitemsMapper cheServiceitemsMapper;

    /**
     * 查询服务管理
     * 
     * @param id 服务管理主键
     * @return 服务管理
     */
    @Override
    public CheServiceitems selectCheServiceitemsById(Long id)
    {
        return cheServiceitemsMapper.selectCheServiceitemsById(id);
    }

    /**
     * 查询服务管理列表
     * 
     * @param cheServiceitems 服务管理
     * @return 服务管理
     */
    @Override
    public List<CheServiceitems> selectCheServiceitemsList(CheServiceitems cheServiceitems)
    {
        return cheServiceitemsMapper.selectCheServiceitemsList(cheServiceitems);
    }

    /**
     * 新增服务管理
     * 
     * @param cheServiceitems 服务管理
     * @return 结果
     */
    @Override
    public int insertCheServiceitems(CheServiceitems cheServiceitems)
    {
        return cheServiceitemsMapper.insertCheServiceitems(cheServiceitems);
    }

    /**
     * 修改服务管理
     * 
     * @param cheServiceitems 服务管理
     * @return 结果
     */
    @Override
    public int updateCheServiceitems(CheServiceitems cheServiceitems)
    {
        return cheServiceitemsMapper.updateCheServiceitems(cheServiceitems);
    }

    /**
     * 批量删除服务管理
     * 
     * @param ids 需要删除的服务管理主键
     * @return 结果
     */
    @Override
    public int deleteCheServiceitemsByIds(Long[] ids)
    {

        return cheServiceitemsMapper.deleteCheServiceitemsByIds(ids);
    }

    /**
     * 删除服务管理信息
     * 
     * @param id 服务管理主键
     * @return 结果
     */
    @Override
    public int deleteCheServiceitemsById(Long id)
    {

        return cheServiceitemsMapper.deleteCheServiceitemsById(id);
    }

//    根据shopId查询
    @Override
    public List<CheServiceitems> selectCheServiceitemsByShopId(Long shopId) {
        return cheServiceitemsMapper.selectServiceitemsByShopId(shopId);
    }
}
